﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Data;

/// <summary>
/// Summary description for ProductBus
/// </summary>
public class ProductBus
{
    ProductDAL productDAL = new ProductDAL();
	public ProductBus()
	{
		//
		// TODO: Add constructor logic here
		//
    }
    //display all product
    public DataTable GetAllProduct()
    {
        return productDAL.GetAllProduct();
    }
    //search Product by Id
    public DataTable GetProductDetailById(string productId)
    {
        DataTable dt = new DataTable();

      
        return productDAL.GetProductById(productId);
    }

    //search Product by 
    public DataTable GetProductDetailAll(string categoryname,string color1, string color2, string color3, string color4, int size1, int size2, int size3, int size4, float price1, float price2)
    {
        DataTable dt = new DataTable();


        return productDAL.GetProductAll(categoryname, color1, color2, color3, color4, size1, size2, size3, size4,price1,price2);
    }

    public DataTable GetUrlImgByCategoryName(string urlimg)
    {
        DataTable dt = new DataTable();
        return productDAL.GetUrlImgbyCategoryName(urlimg);
    }

    public DataTable GetProductDetail(string size1, string color1, float price1, float price2,string CategoryName)
    {
        DataTable dt = new DataTable();
        return productDAL.GetSearchAll01(size1, color1, price1, price2,CategoryName);
    }

    public DataTable GetProductIdByProductName(string ProductName)
    {
        DataTable dt = new DataTable();
        return productDAL.GetProductByName(ProductName);
    }
}